#pragma once
#include "UIComponent.h"
#define PSP_SCREEN_WIDTH 480
#define PSP_SCREEN_HEIGHT 272

class Canvas : public UIComponent{
    private:
        UIComponent* components[MAX_COMP_NUM];
        int copcont;
        int _cursltindx;  //select to canvas itself when equals -1
        OSL_IMAGE *bkg;   //background image
        bool _uilock;
    public:
        Canvas();

        virtual void onselect();
        virtual void onblur();
        virtual void onhover();
        void handlectrl(const OSL_CONTROLLER *);

        int  pagenum;
        int  *totalpagenum;
        void AddComponent(UIComponent*);
        void draw();
        ~Canvas();
};
